package org.scau.studentevaluation.client;

import org.scau.studentevaluation.entity.dos.StudentDO;
import org.scau.studentevaluation.entity.response.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * 通过 Feign 访问学生微服务
 * @Author: x1aolone
 * @Date: 2020/8/27 16:20
 */
@FeignClient(value = "eureka-client-student",
        fallback = StudentClientHystrix.class)
public interface StudentClient {

    /**
     * 【测试通过】
     * 通过feign调用student模块中获取学生信息的方法
     * 通过college从student表中获取数据
     * @param college
     * @return
     */
    @GetMapping("/student/list_students/{college}")
    Result<List<StudentDO>> getStudentInfo(@RequestParam("college") String college);



}
